<!DOCTYPE html>
{% load blog_tags %}
<html>
<head>
    <title>an00</title>

    <!-- meta -->
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <!-- css -->
    {#    <link rel="stylesheet" href="/static/css/bootstrap.min.css">#}
    <link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap.min.css">
    <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
    <link rel="stylesheet" href="/static/css/custom.css">
    <link rel="stylesheet" href="/static/css/highlights/github.css">
    {#    <link rel="stylesheet" href="/static/css/highlights/native.css">#}
    {#    <link href="https://cdn.bootcss.com/bootstrap-markdown/2.10.0/css/bootstrap-markdown.min.css" rel="stylesheet">#}
    {#    <script src="https://cdn.bootcss.com/bootstrap-markdown/2.10.0/js/bootstrap-markdown.min.js"></script>#}

    <!-- js -->
    {#    <script src="/static/js/jquery-2.1.3.min.js"></script>#}
    {#    <script src="/static/js/bootstrap.min.js"></script>#}
    <script src="https://cdn.bootcss.com/jquery/2.2.3/jquery.min.js"></script>
    <script src="https://cdn.bootcss.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
</head>

<body>
{% include 'include/header.html' %}


<div class="content-body">
    <div class="container">
        <div class="row">
            <main class="col-md-9">
                {% block main %}
                {% endblock main %}
            </main>
            <aside class="col-md-3">
                {% block markdown_toc %}
                {% endblock markdown_toc %}
                <div class="widget widget-recent-posts">
                    <h3 class="widget-title">最新文章</h3>
                    {% get_newest_arts as arts %}
                    <ul>
                        {% for art in arts %}
                        <li>
                            <a href="{% url 'blog:detail' pk=art.pk %}">{{ art.title }}</a>
                        </li>
                        {% empty %}
                        <li>暂无更新</li>
                        {% endfor %}
                    </ul>
                </div>
                <div class="widget widget-archives">
                    <h3 class="widget-title">归档</h3>
                    {% get_time_archives as archives %}
                    <ul>
                        {% for archive in archives %}
                        <li>
                            <a href="{% url 'blog:archive' year=archive.year month=archive.month %}">
                                {{ archive.year }} 年 {{ archive.month }} 月
                            </a>
                        </li>
                        {% empty %}
                        <li>暂无归档</li>
                        {% endfor %}
                    </ul>
                </div>
                <div class="widget widget-category">
                    <h3 class="widget-title">分类</h3>
                    {% get_categories as categorys %}
                    <ul>
                        {% for category in categorys %}
                        <li>
                            <a href="{% url 'blog:category' pk=category.pk %}">{{ category.name }}
                                <span class="post-count">({{ category.num_arts }})</span>
                            </a>
                        </li>
                        {% empty %}
                            <li>暂无分类</li>
                        {% endfor %}
                    </ul>
                </div>
                <div class="widget widget-tag-cloud">
                    <h3 class="widget-title">标签云</h3>
                    {% get_tags as tags %}
                    <ul>
                        {% for tag in tags %}
                        <li>
                            <a href="{% url 'blog:tag' pk=tag.pk %}">{{ tag.name }}</a>
                        </li>
                        {% empty %}
                        <li>暂无标签</li>
                        {% endfor %}
                    </ul>
                </div>
                <div class="rss">
                    <a href="{% url 'blog:rss' %}"><span class="ion-social-rss-outline"></span> RSS 订阅</a>
                </div>
            </aside>
        </div>
    </div>
</div>

{% include 'include/footer.html' %}

{#<script src="/static/js/script.js"></script>#}
{% block script %}
{% endblock %}
</body>
</html>
